<template>
  <div class="box">
    <div class="header">{{ title }}</div>
    <div class="content">
      <!--占了一个位置-->
      <slot></slot>
    </div>
    <div class="footer">
      <button>取消</button>
      <button style="margin-left: 30px">确定</button>
    </div>
  </div>
</template>

<script>
export default {
  props: {
    title: String,
  },
};
</script>

<style scoped>
.box {
  border: 1px solid green;
  margin: 10px;
  width: 400px;
  padding: 10px;
}

.header {
  background-color: pink;
  text-align: center;
}

.content {
  height: 300px;
  border: 1px solid red;
}

.footer {
  height: 50px;
  line-height: 50px;
  display: flex;
  justify-content: center;
}
</style>
